<#import "/analysis/function.ftl" as fn>
<@fn.header _title="交换比对统计" />
<body>
<@fn.position _value="当前位置 &gt;&gt; 核对业务统计 &gt; 交换比对统计" />
<div class="contentDiv">
  <div class="condition">
    <h2>统计条件</h2>
    <form id="listForm" method="post">
	    <table class="tableStyle">
	      <tr>
	        <td width="11%">受理时间段：</td>
	        <td width="22%"><input name="acceptStartTime" type="text" class="btnTxtDate" id="textfield" />
	          至
	          <input name="acceptEndTime" type="text" class="btnTxtDate" id="textfield13" />
	          <span class="red">*</span></td>
	        <td width="10%">所属区县：</td>
	        <td width="24%"><select name="countiesRegionId" class="btnSelect" id="select2">
	            <option value="">-- 请选择 --</option>
	          </select>
	          <span class="red">*</span></td>
	        <td width="11%">所属街道：</td>
	        <td width="22%"><select name="streetRegionId" class="btnSelect" id="select3">
	            <option value="">-- 请选择 --</option>
	          </select></td>
	      </tr>
	      <tr>
	        <td>统计范围：</td>
	        <td><select name="rangeType" class="btnSelect" id="select">
	          <option value="0" selected>全部</option>
	          <option value="1">按户数</option>
	          <option value="2">按人数</option>
	        </select></td>
	        <td>&nbsp;</td>
	        <td>&nbsp;</td>
	        <td>&nbsp;</td>
	        <td>&nbsp;</td>
	      </tr>
	    </table>
	    <table class="buttonT">
	      <tr>
	        <td width="10%"><input type="submit" class="button" value="统 计" /></td>
	      </tr>
	    </table>
	  </form>
  </div>
  <div class="reasult">
    <h2>统计结果</h2>
    <form id="exportExcel" action="${base}/checkBusinessStat/exportExcel" method="post">
    <table class="gridStyle">
      <tr>
        <th rowspan="2">区县</th>
        <th rowspan="2">街道</th>
        <th colspan="2">房产局</th>
        <th colspan="2">人社局</th>
        <th colspan="2">地税局</th>
        <th colspan="2">公安局</th>
        <th colspan="2">工商局</th>
		<th colspan="2">住房公积金管理中心</th>
        <th colspan="2">所有委办</th>
      </tr>
      <tr>
        <td> 已发送 </td>
        <td> 已返回 </td>
        <td> 已发送 </td>
        <td> 已返回 </td>
        <td> 已发送 </td>
        <td> 已返回 </td>
        <td> 已发送 </td>
        <td> 已返回 </td>
        <td> 已发送 </td>
        <td> 已返回 </td>
        <td> 已发送 </td>
        <td> 已返回 </td>
		<td> 已发送 </td>
        <td> 已返回 </td>
      </tr>
      <#list resultList as data>
	      <tr>
	        <td<#if rangeType == 0 || (data.streetCompareStatdataList?size>1)> rowspan="<#if rangeType == 0>${2 * data.streetCompareStatdataList?size}<#else>${data.streetCompareStatdataList?size}</#if>"</#if>>${data.countryRegionName}</td>
	        <td<#if rangeType == 0> rowspan="2"</#if>>${data.streetCompareStatdataList[0].streetRegionName}</td>
	        <td>${data.streetCompareStatdataList[0].compareStatDataList[0].fangChanSendNum}</td>
	        <td>${data.streetCompareStatdataList[0].compareStatDataList[0].fangChanRecvNum}</td>
	        <td>${data.streetCompareStatdataList[0].compareStatDataList[0].rensheSendNum}</td>
	        <td>${data.streetCompareStatdataList[0].compareStatDataList[0].rensheRecvNum}</td>
	        <td>${data.streetCompareStatdataList[0].compareStatDataList[0].dishuiSendNum}</td>
	        <td>${data.streetCompareStatdataList[0].compareStatDataList[0].dishuiRecvNum}</td>
	        <td>${data.streetCompareStatdataList[0].compareStatDataList[0].gonganSendNum}</td>
	        <td>${data.streetCompareStatdataList[0].compareStatDataList[0].gonganRecvNum}</td>
	        <td>${data.streetCompareStatdataList[0].compareStatDataList[0].gongshangSendNum}</td>
	        <td>${data.streetCompareStatdataList[0].compareStatDataList[0].gongshangRecvNum}</td>
	        <td>${data.streetCompareStatdataList[0].compareStatDataList[0].gongjijinSendNum}</td>
	        <td>${data.streetCompareStatdataList[0].compareStatDataList[0].gongjijinRecvNum}</td>
	        <td>${data.streetCompareStatdataList[0].compareStatDataList[0].sendNumSum}</td>
	        <td>${data.streetCompareStatdataList[0].compareStatDataList[0].recvNumSum}</td>
	      </tr>
	      <#if rangeType == 0>
		      <tr>
		        <td>${data.streetCompareStatdataList[0].compareStatDataList[1].fangChanSendNum}</td>
		        <td>${data.streetCompareStatdataList[0].compareStatDataList[1].fangChanRecvNum}</td>
		        <td>${data.streetCompareStatdataList[0].compareStatDataList[1].rensheSendNum}</td>
		        <td>${data.streetCompareStatdataList[0].compareStatDataList[1].rensheRecvNum}</td>
		        <td>${data.streetCompareStatdataList[0].compareStatDataList[1].dishuiSendNum}</td>
		        <td>${data.streetCompareStatdataList[0].compareStatDataList[1].dishuiRecvNum}</td>
		        <td>${data.streetCompareStatdataList[0].compareStatDataList[1].gonganSendNum}</td>
		        <td>${data.streetCompareStatdataList[0].compareStatDataList[1].gonganRecvNum}</td>
		        <td>${data.streetCompareStatdataList[0].compareStatDataList[1].gongshangSendNum}</td>
		        <td>${data.streetCompareStatdataList[0].compareStatDataList[1].gongshangRecvNum}</td>
		        <td>${data.streetCompareStatdataList[0].compareStatDataList[1].gongjijinSendNum}</td>
		        <td>${data.streetCompareStatdataList[0].compareStatDataList[1].gongjijinRecvNum}</td>
		        <td>${data.streetCompareStatdataList[0].compareStatDataList[1].sendNumSum}</td>
		        <td>${data.streetCompareStatdataList[0].compareStatDataList[1].recvNumSum}</td>
		      </tr>
	      </#if>
	      <#if (data.streetCompareStatdataList?size>1)>
		      <#list data.streetCompareStatdataList[1..] as _data>
			      <tr>
			        <td<#if rangeType == 0> rowspan="2"</#if>>${_data.streetRegionName}</td>
			        <td>${_data.compareStatDataList[0].fangChanSendNum}</td>
			        <td>${_data.compareStatDataList[0].fangChanRecvNum}</td>
			        <td>${_data.compareStatDataList[0].rensheSendNum}</td>
			        <td>${_data.compareStatDataList[0].rensheRecvNum}</td>
			        <td>${_data.compareStatDataList[0].dishuiSendNum}</td>
			        <td>${_data.compareStatDataList[0].dishuiRecvNum}</td>
			        <td>${_data.compareStatDataList[0].gonganSendNum}</td>
			        <td>${_data.compareStatDataList[0].gonganRecvNum}</td>
			        <td>${_data.compareStatDataList[0].gongshangSendNum}</td>
			        <td>${_data.compareStatDataList[0].gongshangRecvNum}</td>
			        <td>${_data.compareStatDataList[0].gongjijinSendNum}</td>
			        <td>${_data.compareStatDataList[0].gongjijinRecvNum}</td>
			        <td>${_data.compareStatDataList[0].sendNumSum}</td>
			        <td>${_data.compareStatDataList[0].recvNumSum}</td>
			      </tr>
			     <#if rangeType == 0>
			      <tr>
			        <td>${_data.compareStatDataList[1].fangChanSendNum}</td>
			        <td>${_data.compareStatDataList[1].fangChanRecvNum}</td>
			        <td>${_data.compareStatDataList[1].rensheSendNum}</td>
			        <td>${_data.compareStatDataList[1].rensheRecvNum}</td>
			        <td>${_data.compareStatDataList[1].dishuiSendNum}</td>
			        <td>${_data.compareStatDataList[1].dishuiRecvNum}</td>
			        <td>${_data.compareStatDataList[1].gonganSendNum}</td>
			        <td>${_data.compareStatDataList[1].gonganRecvNum}</td>
			        <td>${_data.compareStatDataList[1].gongshangSendNum}</td>
			        <td>${_data.compareStatDataList[1].gongshangRecvNum}</td>
			        <td>${_data.compareStatDataList[1].gongjijinSendNum}</td>
			        <td>${_data.compareStatDataList[1].gongjijinRecvNum}</td>
			        <td>${_data.compareStatDataList[1].sendNumSum}</td>
			        <td>${_data.compareStatDataList[1].recvNumSum}</td>
			      </tr>
		        </#if>
		      </#list>
		     
	      </#if>
	  </#list>
    </table>
	<table class="buttonT">
      <tr>
        <td width="10%"><input type="submit" class="button" value="导出Excel" /></td>
      </tr>
    </table>
  </div>
  <div class="explain">
    <h3>说明：</h3>
    <p>1. 以户为单位进行统计时，家庭中所有人对所有委办都已发送成功，该户才算发送成功，返回亦如此。</p>
    <p>2. 未选择统计条件的情况下，默认登陆用户权限下“开始至今”所有数据的统计。</p>
    <p>3. 统计表可下载（excel)、打印。</p>
    <p>4. 用户可以根据&quot;统计范围&quot;条件选择仅选择&quot;户&quot;或&quot;人&quot;，缺省统计&quot;全部&quot;。</p>
  </div>
</div>
</body>
</html>
